EasyCoding.uz

Home / Python / Data Types

Data Types & Variables

Mark Complete

Python understands the type based on the value you assign.

Common Types

  • int for whole numbers
  • float for decimals
  • str for text
  • list, tuple, dict, set
Key takeaway: choose clear variable names.

Example

age = 18
price = 19.99
name = "Ali"
scores = [90, 85, 92]
user = {"name": "Ali", "age": 18}

Ready to try it yourself?

Create variables with different types.

← Introduction Control Flow →